The present invention relates to an image processing apparatus which composes an image while receiving first compressed data generated by compressing a first piece of image data, second compressed data generated by compressing a second piece of image data that is different from the first piece of image data, and third compressed data generated by compressing selection data to be used for making a selection between the first piece of image data and the second piece of image data. Further, the present invention also relates to color facsimile machines, or to transmission/reception of images of the Internet.
In recent years, the transmission rate of image data has increased rapidly because of development of networks such as the Internet and public lines and advancement of the image compression technology. With the increase in transmission rate, transmittable image data have been improved in resolution and increased in the number of gradation levels, and their colorization has advanced; even a full-color image of 400 dpi (dots per inch) is now a practical transmission object. Incidentally, in transmitting such a full-color image via a network or a public line, image compression is usually performed. In such a case, the JPEG algorithm is generally used as a compression algorithm. Further, image storage such as image filing is now popular, and data that have been compressed, as in the above case, by using the JPEG algorithm or the like are used for storage of color images.
Now, the JPEG algorithm will be described, starting from the compression algorithm. If necessary, input image data is subjected to color space conversion from the RGB color space to the L*a*b* space, for example. Thereafter, the image data is divided into blocks of 8.times.8 pixels, converted into the frequency domain by DCT (discrete cosine transform) on a block-by-block basis, and then quantized by using a quantization table having the same size as each block. Then, the block data are converted by a zigzagged scan into raster data, from which compressed data is generated by two-dimensional Huffman coding. The expansion algorithm is an algorithm reverse to the compression algorithm. Image data is restored by Huffman decoding, raster-block conversion, dequantization, and IDCT (inverse DCT).
However, since quantization, which is a non-reversible process, is performed in the JPEG algorithm as seen from the above description, an expanded image is deteriorated in image quality from image data before the compression. Usually, to increase the compression ratio, a quantization table in which the quantization step is made larger as the frequency increases is used. Therefore, in particular, the image quality deteriorates remarkably and the compression ratio decreases at portions (characters, line figures, etc.) having edges that include many high-frequency components [of large amplitudes].